import request from '@/utils/request'

// 查询大乐透列表
export function listLotto(query) {
  return request({
    url: '/gamble/lotto/list',
    method: 'get',
    params: query
  })
}

// 查询大乐透详细
export function getLotto(lottoId) {
  return request({
    url: '/gamble/lotto/' + lottoId,
    method: 'get'
  })
}

// 新增大乐透
export function addLotto(data) {
  return request({
    url: '/gamble/lotto',
    method: 'post',
    data: data
  })
}

// 修改大乐透
export function updateLotto(data) {
  return request({
    url: '/gamble/lotto',
    method: 'put',
    data: data
  })
}

// 删除大乐透
export function delLotto(lottoId) {
  return request({
    url: '/gamble/lotto/' + lottoId,
    method: 'delete'
  })
}

// 预估大乐透
export function estimatelLotto() {
  return request({
    url: '/gamble/lotto/estimate',
    method: 'get'
  })
}
